473,461 Members | 1,787 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Tab spacing in text using CSS

132 100+
Hi there.

I'm new to CSS and I am wondering how I can format text in a way such as the following:

Bold Text [ ]This is a sample line of text that would be tab-spaced
[ ]after the bold text on the left.


Hence I want to apply a tab (or margin) on the same line as the bold string..? This not showing above as I can't get the tab effect to work when posting on here, but in the example above, the two [ ] boxes would line up vertically if the tab was working. Hence blocking the standard text away from the bold text. Hopefully that makes sense..?

Any help will be much appreciated.

Thank you.

M :o)
Feb 17 '09 #1
3 9504
Dormilich
8,658 Expert Mod 8TB
I'd probably float the bold text, since you never know the actual width of a tab (may be dependent on user setting)
Feb 17 '09 #2
drhowarddrfine
7,435 Expert 4TB
Expand|Select|Wrap|Line Numbers
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <title></title>
  5. <style type="text/css">
  6. span{margin-right:1em;font-weight:bold}
  7. </style>
  8. </head>
  9. <body>
  10. <p><span>Once</span> upon a time</p>
  11. </body>
  12. </html>
  13.  
  14.  
Feb 17 '09 #3
David Laakso
397 Expert 256MB
Need more information on the need and use intended. If your running blocks of text then this is one simple method:
http://chelseacreekstudio.com/ca/cssd/indent.html
If you're running blocks of text, and are of an accessibility bent, and need it to make sense in a Lynx viewer, the solution could become a little more difficult...
Feb 17 '09 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: Danny | last post by:
I have a small <div> element which contains two text blocks - one within <h5> tags and the other within <p> tags. I don't want any extra line spacing between elements so use the display:inline...
1
by: Bishman | last post by:
Hi, I have been trying to get text to scroll smoothly accross a windows form using GDI+ and a timer. Changing the position of the text by a configurable amount and calling invalidate to force a...
3
by: nskclr | last post by:
Hi I add a text using document.selection.createRange(). I want to add a text to the bottom of another text - similar to what we do in HTML. <p> xyz </p> <p><div...
1
by: anilraja | last post by:
how to search within text using vbscript?
3
by: f6600840 | last post by:
Hi, What function I should use if I want to clean text using perl. Example. Input for my perl based shell command is SMI-1234 566.5.2.3.4.5.5.192.168.1.1 = "huuhaa" : SMI-1234...
3
by: RuthC | last post by:
How to create a warped text using javascript? Is it possible..? pls help me ...
2
by: RuthC | last post by:
how to create arc text using php
5
by: padmaneha | last post by:
How to omit replacement in somepart of text using regular expression? For ex: If i want to replace mumbai with mumbai/aaa.com but if i have an anchor tag <a...
4
by: research_stuff | last post by:
I have researched unhiding text using Javascript. I found examples unhiding text boxes. I need to unhide text when a radio button has been selected. Can someone point me to an example? ...
4
by: interr0bangr | last post by:
Hey all, Does anyone have any tips when coding superscript for email newsletters? My client uses insane amounts of superscripted characters (usually to reference the legal fine print) and I've...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.